<template>
  <!-- <StyleProvider hash-priority="high" :transformers="[legacyLogicalPropertiesTransformer]"> -->
  <ConfigProvider :locale="getAntdLocale" :theme="isDark ? darkTheme : lightTheme">
    <AppProvider>
      <RouterView />
    </AppProvider>
  </ConfigProvider>
  <!-- </StyleProvider> -->
</template>

<script lang="ts" setup>
  import {
    ConfigProvider,
    // StyleProvider,
    // legacyLogicalPropertiesTransformer,
  } from 'ant-design-vue';
  import { AppProvider } from '/@/components/Application';
  import { useTitle } from '/@/hooks/web/useTitle';
  import { useFavicon } from '/@/hooks/web/useFavicon';
  import { useLocale } from '/@/locales/useLocale';
  import { useDarkModeTheme } from '/@/hooks/setting/useDarkModeTheme';
  // import 'ant-design-vue/dist/reset.css';

  import 'dayjs/locale/zh-cn';

  const { isDark, darkTheme, lightTheme } = useDarkModeTheme();

  // support Multi-language
  const { getAntdLocale } = useLocale();

  // Listening to page changes and dynamically changing site titles
  useTitle();

  useFavicon();
</script>
